package com.example.demo;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author weiZhiLin
 * @version 1.0
 * @date 2021/6/21 12:03
 */
@RestController
public class MainController {
    @Value("${server.port}")
    String port;

    @GetMapping("/getPort")
    public String gugu() {
        int i = 1 / 0;

        return port;
    }
}
